package com.hermit.server.dto;

<#list typeSet as type>
    <#if type=='Date'>
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
    </#if>
    <#if type=='BigDecimal'>
import java.math.BigDecimal;
    </#if>
</#list>
/** Dto类 */
public class ${Domain}Dto {
    <#list fieldList as field>
        <#if field.javaType=="Date">
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
        </#if>
    private ${field.javaType} ${field.nameHump};
    </#list>
    /**set与get方法  */
    <#list fieldList as field>
    public ${field.javaType} get${field.nameBigHump}(){
        return ${field.nameHump};
    }

    public void set${field.nameBigHump}(${field.javaType} ${field.nameHump}){
        this.${field.nameHump} = ${field.nameHump};
    }
    </#list>

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        <#list fieldList as field>
        sb.append(",${field.nameHump}=").append(${field.nameHump});
        </#list>
        sb.append("]");
        return sb.toString();
    }
}